package com.stm.meet.Service;

import com.stm.meet.Entitys.CardEntity;
import com.stm.meet.Repository.CardRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CardService {

    @Autowired
    CardRepository repository;

    public void saveCards(List<CardEntity> list){
        repository.save(list);
    }

    public List<CardEntity> getMeetCards(Integer id){
        return repository.findAllByMeetId(id);
    }

}
